<%= link_to_remote('refresh', :url=>{:controller=>'task',:action=>'display_deadlines'}, :update=>'deadlines_content')%>
<div class="section">Past</div>
<ul>
<%= render(:partial=>'task/task', :collection=>@deadlines.select {|t| t.duedate < Date.today}, :locals=>{:tasks=>@tasks, :item_name=>'dl'}) %>
</ul>
<div class="section">Today</div>
<ul>
<%= render(:partial=>'task/task', :collection=>@deadlines.select {|t| t.duedate == Date.today}, :locals=>{:tasks=>@tasks, :item_name=>'dl'}) %>
</ul>
<div class="section">Soon</div>
<ul>
<%= render(:partial=>'task/task', :collection=>@deadlines.select {|t| t.duedate > Date.today}, :locals=>{:tasks=>@tasks, :item_name=>'dl'}) %>
</ul>

